RAIS  3.2
C:/Projekte/RAIS/Specific Masks/RegSys.aspx.cs
Go to the documentation of this file.
00001 
00028 using System;
00029 using System.Data;
00030 using System.Configuration;
00031 using System.Collections;
00032 using System.Web;
00033 using System.Web.Security;
00034 using System.Web.UI;
00035 using System.Web.UI.WebControls;
00036 using System.Web.UI.WebControls.WebParts;
00037 using System.Web.UI.HtmlControls;
00038 
00039 using RAIS.Common.UserManagement;
00040 //using RAIS.ApplicationLogicLayer;
00041 
00042 namespace RAIS.UI.SpecificMasks
00043 {
00047     public partial class RegSys : System.Web.UI.Page
00048     {
00049                 //*********************************************************************
00050                 #region Properties
00051 
00054                 protected UserData CurrentUser
00055                 {
00056                         get { return (UserData)this.Session[UI.Common.Constants.CURRENT_USER_TAG]; }
00057                 }
00061                 protected bool ShowHidden
00062                 {
00063                         get
00064                         {
00065                                 //if (this.Session[UI.Common.Constants.SHOW_HIDDEN_STATE_TAG] != null)
00066                                 //    return (bool)this.Session[UI.Common.Constants.SHOW_HIDDEN_STATE_TAG];
00067                                 //else
00068                                 //    return false;
00069                                 return UI.Common.PageManagement.GetShowProtectors(this)
00070                                         || UI.Common.PageManagement.GetShowEvaluators(this);
00071                         }
00072                         set
00073                         {
00074                                 this.Session[UI.Common.Constants.SHOW_HIDDEN_STATE_TAG] = value;
00075                         }
00076                 }
00077                 #endregion
00078                 //*********************************************************************
00079                 #region Event handlers
00080         protected void Page_PreLoad(object sender, EventArgs e)
00081         {
00082             RAIS.UI.Common.PageManagement.TrimTextBoxValues(this);
00083         }
00090         protected void Page_Load(object sender, EventArgs e)
00091         {
00092                         this.Response.Cache.SetNoStore();
00093                         if (this.CurrentUser == null)
00094                                 UI.Common.AccessManagement.SignOut(this);
00095                         
00096                         if (!this.IsPostBack)
00097             {
00098                 this.LBLusernameNoTranslation.Text = this.CurrentUser.Name;
00099 
00100                                 //this.CBshowHidden.Visible =
00101                                 //    (this.CurrentUser.FunctionalRole.Type == FunctionRole.FunctionRoleType.Administrator);
00102                                 //this.CBshowHidden.Checked = this.ShowHidden;
00103 
00104                                 UI.Common.PageManagement.InitializePageTreeForCategory(this, this.TreeView1, RAIS.Common.Constants.CATEGORY_NAME_REGULATORY_SYSTEM, this.ShowHidden);
00105                 UI.Common.UserManagement.EnableCommonControls(this, true);
00106                 this.LBLregsys.ForeColor = RAIS.UI.Common.Constants.COLOR_OF_MENU_BAR_TEXT_HIGHLIGHT;
00107 //                              this.LBTNmessagebox.Visible = !(this.CurrentUser.FunctionalRole.Type == FunctionRole.FunctionRoleType.Guest);
00108                         }
00109         }
00115                 protected void CBshowHidden_CheckedChanged(object sender, EventArgs e)
00116                 {
00117                         this.ShowHidden = CBshowHidden.Checked;
00118                         UI.Common.PageManagement.InitializePageTreeForCategory(this, this.TreeView1, RAIS.Common.Constants.CATEGORY_NAME_REGULATORY_SYSTEM, this.ShowHidden);
00119                 }
00126         protected void TreeView1_SelectedNodeChanged(object sender, EventArgs e)
00127         {
00128             UI.Common.UserManagement.ProcessTreeViewOnRedirect(this.TreeView1);
00129         }
00136         protected void LBTNlogout_Click(object sender, EventArgs e)
00137         {
00138             UI.Common.AccessManagement.SignOut(this);
00139         }
00140         #endregion
00141                 //*********************************************************************
00142                 #region Private helper methods
00143         #endregion
00144     }
00145 }